<html>
<head><meta charset="utf-8"><title>lldb with rust support? · general · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/index.html">general</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html">lldb with rust support?</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="221310439"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221310439" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oxalica <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221310439">(Dec 31 2020 at 19:16)</a>:</h4>
<p>Currently, lldb doesn't work well with rust enums (<a href="https://github.com/rust-lang/rust/issues/79530">https://github.com/rust-lang/rust/issues/79530</a>).<br>
I found a patched lldb fork (<a href="https://github.com/rust-lang/lldb/tree/rust-release-80-v2">https://github.com/rust-lang/lldb/tree/rust-release-80-v2</a>) which works well on enums and also used by vadimcn/vscode-lldb. But rust-lang/lldb  is not maintained anymore. The lldb patch is not included in the new repository rust-lang/llvm-project.<br>
Why is it removed? Is there any plan to add the lldb patch back for the new version of LLVM?</p>



<a name="221325878"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221325878" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221325878">(Jan 01 2021 at 00:07)</a>:</h4>
<p><span class="user-mention" data-user-id="240608">@hooccooh</span> the person who used to maintain Rust debugger support left the project, so it's probably just in limbo</p>



<a name="221325884"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221325884" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221325884">(Jan 01 2021 at 00:07)</a>:</h4>
<p>if those patches were upstreamed, I would be very happy</p>



<a name="221326283"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221326283" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221326283">(Jan 01 2021 at 00:16)</a>:</h4>
<p>IIRC LLVM wouldn't take the patches, they were stuck in review for months</p>



<a name="221326284"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221326284" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221326284">(Jan 01 2021 at 00:16)</a>:</h4>
<p>hold on let me find the thread</p>



<a name="221326322"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221326322" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oxalica <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221326322">(Jan 01 2021 at 00:17)</a>:</h4>
<p>Oh I finally found the author of vscode-lldb are already doing this recently in another repo <a href="https://github.com/vadimcn/llvm-project/tree/codelldb/11.0.0">https://github.com/vadimcn/llvm-project/tree/codelldb/11.0.0</a><br>
I'm trying it.</p>



<a name="221326470"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221326470" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221326470">(Jan 01 2021 at 00:20)</a>:</h4>
<p>I found at least <a href="#narrow/stream/131828-t-compiler/topic/Structural.20match.20marker.20traits/near/193106822">https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/Structural.20match.20marker.20traits/near/193106822</a> but I thought there was another thread with more info :/</p>



<a name="221326483"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221326483" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221326483">(Jan 01 2021 at 00:21)</a>:</h4>
<p>ok yes here we go <a href="#narrow/stream/122651-general/topic/Adding.20Rust.20v0.20demangling.20support.20to.20LLVM">https://rust-lang.zulipchat.com/#narrow/stream/122651-general/topic/Adding.20Rust.20v0.20demangling.20support.20to.20LLVM</a></p>



<a name="221326569"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221326569" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221326569">(Jan 01 2021 at 00:23)</a>:</h4>
<p>so yeah, waiting on LLVM, not the rust side</p>



<a name="221327291"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221327291" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221327291">(Jan 01 2021 at 00:41)</a>:</h4>
<p>oh, that's for demangling</p>



<a name="221327441"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221327441" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221327441">(Jan 01 2021 at 00:46)</a>:</h4>
<p>that's different</p>



<a name="221327459"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221327459" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221327459">(Jan 01 2021 at 00:47)</a>:</h4>
<p>I don't know if we tried to upstream the enum support. I think possibly the thinking at one time was that we wanted to iterate on (and possibly distribute) our own fork a bit before "committing" to something by upstreaming</p>



<a name="221327524"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221327524" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221327524">(Jan 01 2021 at 00:48)</a>:</h4>
<p>but my experience with enum/variant debuginfo is that DWARF is already general enough to describe everything we do, so fixes we make aren't usually specific to Rust anyway</p>



<a name="221327548"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221327548" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221327548">(Jan 01 2021 at 00:50)</a>:</h4>
<p>so I think we should upstream it rather than maintaining custom forks, if possible</p>



<a name="221327718"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221327718" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221327718">(Jan 01 2021 at 00:54)</a>:</h4>
<p>but dunno who has time to make it happen</p>



<a name="221336479"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221336479" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221336479">(Jan 01 2021 at 05:22)</a>:</h4>
<p>I personally would like to invest in this</p>



<a name="221336483"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/122651-general/topic/lldb%20with%20rust%20support%3F/near/221336483" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/122651-general/topic/lldb.20with.20rust.20support.3F.html#221336483">(Jan 01 2021 at 05:22)</a>:</h4>
<p>And am hoping to find a way to do so</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>